import { http } from "@/utils/http";
import { baseUrlApi } from "./utils";
/**获取文件夹 文件列表 */
export const getCloudList = params => {
  return http.request("get", baseUrlApi("/document/selectList"), { params });
};
// 删除文件 文件夹
export const delCloudFile = params => {
  return http.request("get", baseUrlApi("/document/del"), { params });
};

//移动文件或文件夹
export const moveCloudFile = params => {
  return http.request("get", baseUrlApi("/document/move"), { params });
};
//复制文件或文件夹
export const copyCloudFile = params => {
  return http.request("get", baseUrlApi("/document/copy"), { params });
};

//新增.更新文件或文件夹
export const addCloudFile = data => {
  return http.request("post", baseUrlApi("/document/addOrUpdate"), { data });
};
//收藏接口
export const collectCloudFile = params => {
  return http.request("get", baseUrlApi("/labelModel/storeUp"), { params });
};

//获取文件夹树形结构
export const getCloudTree = () => {
  return http.request("get", baseUrlApi("/document/dirTreeList"));
};
